Skip to content

Instantly share code, notes, and snippets.

@augmt
augmt / organizing-photos-with-duplicate-and-similarity-checking.md
Last active October 11, 2026 08:57
Detecting similar and identical images using perseptual hashes

Detecting similar and identical images using perseptual hashes

Couple of my hobbies are travelling and photography. I love to take pictures and experiment with photography. Usually after my trips, I just copy the photos to either my iPad or couple of my external hard disks. After 10 years, I have over 200K photos distributed across several disks and machines. I had to find a way to organize these photos and create a workflow for future maintenance. In this post I want to address one of the issues I had to solve: ** finding duplicate images **.

First, I needed to find out what exactly is a duplicate image. Analysing my photos, I found couple of interesting things:

  1. Identical images: There were multiple copies of the same photo in different directories with different names.
  2. Similar images: I usually bracket (exposure compensate or flash compensate) important pictures. So I have photos that visually appear to be the same, but may be a little darker/lighter based on e
@matthewzring
matthewzring / markdown-text-101.md
Last active October 11, 2026 08:53
A guide to Markdown on Discord.

Markdown Text 101

Want to inject some flavor into your everyday text chat? You're in luck! Discord uses Markdown, a simple plain text formatting system that'll help you make your sentences stand out. Here's how to do it! Just add a few characters before & after your desired text to change your text! I'll show you some examples...

What this guide covers:

ls - The most frequently used command in Linux to list directories
pwd - Print working directory command in Linux
cd - Linux command to navigate through directories
mkdir - Command used to create directories in Linux
mv - Move or rename files in Linux
cp - Similar usage as mv but for copying files in Linux
rm - Delete files or directories
touch - Create blank/empty files
ln - Create symbolic links (shortcuts) to other files
cat - Display file contents on the terminal
@smi-falcon
smi-falcon / RuStore-Downloader.js
Last active October 11, 2026 08:52
Пользовательский скрипт для добавления кнопки прямого скачивания APK-файлов на страницы приложений RuStore.
// ==UserScript==
// @name RuStore Downloader
// @namespace http://tampermonkey.net/
// @version 1.5.1
// @description Добавление кнопки скачивания APK на страницы приложений RuStore.
// @downloadURL https://gist.githubusercontent.com/smi-falcon/f75edfb5c0143f81ff6ea25e315f0964/raw/RuStore-Downloader.js
// @updateURL https://gist.githubusercontent.com/smi-falcon/f75edfb5c0143f81ff6ea25e315f0964/raw/RuStore-Downloader.js
// @homepageURL https://gist.github.com/smi-falcon/f75edfb5c0143f81ff6ea25e315f0964
// @supportURL https://github.com/smi-falcon
// @author Falcon
@william-reed
william-reed / erwin.js
Created March 2, 2022 01:20
erwin.vw.com download all documents
// once you have a one day plan:
// 1. navigate to your vehicles page under 'Service Information'
// 2. Leave 'Category 1' set to '[Category 1]' and click search
// 3. Open your JS console
// get all document titles
titles = document.getElementsByClassName("title")
documentIds = []
// extract each document id
@pavlov99
pavlov99 / deque.awk
Last active October 11, 2026 08:45
AWK data structures
function deque_init(d) {d["+"] = d["-"] = 0}
function deque_is_empty(d) {return d["+"] == d["-"]}
function deque_push_back(d, val) {d[d["+"]++] = val}
function deque_push_front(d, val) {d[--d["-"]] = val}
function deque_back(d) {return d[d["+"] - 1]}
function deque_front(d) {return d[d["-"]]}
function deque_pop_back(d) {if(deque_is_empty(d)) {return NULL} else {i = --d["+"]; x = d[i]; delete d[i]; return x}}
function deque_pop_front(d) {if(deque_is_empty(d)) {return NULL} else {i = d["-"]++; x = d[i]; delete d[i]; return x}}
function deque_print(d){x="["; for (i=d["-"]; i<d["+"] - 1; i++) x = x d[i]", "; print x d[d["+"] - 1]"]; size: "d["+"] - d["-"] " [" d["-"] ", " d["+"] ")"}
@karpathy
karpathy / microgpt.py
Last active October 11, 2026 08:43
microgpt
"""
The most atomic way to train and run inference for a GPT in pure, dependency-free Python.
This file is the complete algorithm.
Everything else is just efficiency.
@karpathy
"""
import os # os.path.exists
import math # math.log, math.exp
@ProdeusUnity
ProdeusUnity / windowsimagecollection.md
Last active October 11, 2026 08:40
Windows ISO list
OS Version Arch File Host Size Download Link Rate Limits
Windows 1.0 8086 Winworld (Kansas City, Missouri) 541KB Download ❌ Yes, 25 per day, 50 logged in
Windows 2.0 386 Winworld (Kansas City, Missouri) 2.80MB Download ❌ Yes, 25 per day, 50 logged in
Windows 3.

How to WEBrip Audio and Video Using OBS on Linux for Beginners (to give back to the seven seas)

  1. Start OBS and open settings. Set the the recording canvas and output canvas to that of the video playback resolution. So if the playback is 1080p, set both to 1080p.

  2. Set the recording bitrate. This number may needing a bit of tweaking, but the bigger the number, the higher the quality. You will reach a point of diminishing returns depending on the video's resolution, but it's good to do some test recordings and view the clip to check if it's ok. Here is a chart for the standard bitrates:

Type Video Bitrate, Standard Frame Rate (24, 25, 30) Video Bitrate, High Frame Rate (48, 50, 60)
2160p (4K) 35–45 Mbps 53–68 Mbps
1440p (2K) 16 Mbps 24 Mbps
@velzie
velzie / manifest-v2-chrome.md
Last active October 11, 2026 08:26
How to keep using adblockers on chrome and chromium

NOTE

by the time you're reading this, this probably no longer works since the policy has been removed. I reccomend you to check out https://github.com/r58Playz/uBlock-mv3 instead

How to keep using adblockers on chrome and chromium

  1. google's manifest v3 has no analouge to the webRequestBlocking API, which is neccesary for (effective) adblockers to work
  2. starting in chrome version 127, the transition to mv3 will start cutting off the use of mv2 extensions alltogether
  3. this will inevitably piss of enterprises when their extensions don't work, so the ExtensionManifestV2Availability key was added and will presumably stay forever after enterprises complain enough

You can use this as a regular user, which will let you keep your mv2 extensions even after they're supposed to stop working